

package com.example.controller;


import com.example.dal.dict.DictDataDO;
import com.example.mapper.DictDataMapper;
import jakarta.annotation.Resource;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/system/dict-data")
@Validated
public class DictDataController {

    @Resource
    private DictDataMapper dictDataMapper;


    @GetMapping(value = {"/list-all-simple", "simple-list"})
    // 无需添加权限认证，因为前端全局都需要
    public List<DictDataDO> getSimpleDictDataList() {
        List<DictDataDO> list = dictDataMapper.selectDictList();
        return list;
    }
}
